layui.define(function (exports) {

	function BaseApi(module, pathPrefix) {
		this.module = module;
		this.prefix = pathPrefix;
		this.permissionPrefix = 'perm:' + module + ':';
		this.permission = {
			create: this.permissionPrefix + 'create',
			remove: this.permissionPrefix + 'remove',
			update: this.permissionPrefix + 'update',
			list: this.permissionPrefix + 'list',
			detail: this.permissionPrefix + 'detail',
		};
		this.api = {
			create: this.prefix + 'insertUser',
			remove: this.prefix + 'deleteById',
			update: this.prefix + 'update',
			list: this.prefix + 'list',
			getPageList: this.prefix + 'pageList',
			postPageList: this.prefix + 'pageList',
			detail: this.prefix + 'detail',
		};
	}

	exports('BaseApi', BaseApi);
})